package com.ubxtech.cloud.client;

import com.ubxtech.core.context.Result;
import com.ubxtech.core.dto.MsgSendDTO;
import io.swagger.v3.oas.annotations.Operation;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

/**
 * 需要在下游服务中有该接口
 * @author Victor.Xiao
 * @since 2023-11-23 20:24
 **/
public interface MsgPushClient {

    /**
     * 推送到消息中心,自动生成该FeignClient
     * @author Victor.Xiao
     * @since 2023-11-23 20:37
     * @param msg msg
     * @return com.ubxtech.core.context.Result<java.lang.Void>
    */
    @Operation(summary = "推送消息")
    @PostMapping
    <T> Result<Void> pushMsg(@RequestBody MsgSendDTO<T> msg);
}
